package com.chance.cc.crawler.prod.command.trigger.domain.news.qimai;

import com.chance.cc.crawler.core.CrawlerJob;
import com.chance.cc.crawler.meta.core.bean.CrawlerMetaConstant;
import com.chance.cc.crawler.prod.command.job.domain.news.qimai.QimaiPublishCrawlerSchedulerJob;
import com.chance.cc.crawler.prod.command.trigger.CommonCrawlerSchedulerTrigger;

/**
 * @ClassName song
 * @Description TODO
 * @Author ding
 * @Date 2021/9/9 14:11
 * @Version 1.0
 **/
public class QimaiCommonCrawlerScheduleTrigger extends CommonCrawlerSchedulerTrigger {
    public static void main(String[] args) {
     publishQimaiAppStoreRealtimeCrawlerScheduleTriggerInfo();
     //publishQimaioppoRealtimeCrawlerScheduleTriggerInfo();
      // publishQimaihuaweiRealtimeCrawlerScheduleTriggerInfo();
      // publishQimaimiRealtimeCrawlerScheduleTriggerInfo();
       // publishQimaivivoRealtimeCrawlerScheduleTriggerInfo();


        //publishQimaiAppStoreRealtimeSimpleCrawlerScheduleTriggerInfo();
    }
    //苹果采集
    public static void publishQimaiAppStoreRealtimeSimpleCrawlerScheduleTriggerInfo(){
        CrawlerJob crawlerJob = QimaiPublishCrawlerSchedulerJob.appStore();

        metaServiceCommand_17.addOrUpdateScheduleCrawlerTrigger(
                crawlerJob.generateCrawlerKey(),
                crawlerJob.generateCrawlerTriggerKey(),
                QimaiPublishCrawlerSchedulerJob.domain,
                CrawlerMetaConstant.ScheduleJobTrigger_Simple,
                "",
                "七麦苹果  临时采集任务执行"
        );
    }

    //苹果采集
    public static void publishQimaiAppStoreRealtimeCrawlerScheduleTriggerInfo(){
        CrawlerJob crawlerJob = QimaiPublishCrawlerSchedulerJob.appStore();

        metaServiceCommand_17.addOrUpdateScheduleCrawlerTrigger(
                crawlerJob.generateCrawlerKey(),
                crawlerJob.generateCrawlerTriggerKey(),
                QimaiPublishCrawlerSchedulerJob.domain,
                CrawlerMetaConstant.ScheduleJobTrigger_Cron,
                "0 0 17 * * ?",
                "七麦苹果  采集任务执行，每天17点开始执行"
        );
    }
    //oppo采集
    public static void publishQimaioppoRealtimeCrawlerScheduleTriggerInfo(){
        CrawlerJob crawlerJob = QimaiPublishCrawlerSchedulerJob.oppo();

        metaServiceCommand_17.addOrUpdateScheduleCrawlerTrigger(
                crawlerJob.generateCrawlerKey(),
                crawlerJob.generateCrawlerTriggerKey(),
                QimaiPublishCrawlerSchedulerJob.domain,
                CrawlerMetaConstant.ScheduleJobTrigger_Cron,
                "0 0 17 * * ?",
                "七麦oppo  采集任务执行，每天17点开始执行"
        );
    }
    //huawei采集
    public static void publishQimaihuaweiRealtimeCrawlerScheduleTriggerInfo(){
        CrawlerJob crawlerJob = QimaiPublishCrawlerSchedulerJob.huawei();

        metaServiceCommand_17.addOrUpdateScheduleCrawlerTrigger(
                crawlerJob.generateCrawlerKey(),
                crawlerJob.generateCrawlerTriggerKey(),
                QimaiPublishCrawlerSchedulerJob.domain,
                CrawlerMetaConstant.ScheduleJobTrigger_Cron,
                "0 0 17 * * ?",
                "七麦华为  采集任务执行，每天17点开始执行"
        );
    }
    //mi采集
    public static void publishQimaimiRealtimeCrawlerScheduleTriggerInfo(){
        CrawlerJob crawlerJob = QimaiPublishCrawlerSchedulerJob.mi();

        metaServiceCommand_17.addOrUpdateScheduleCrawlerTrigger(
                crawlerJob.generateCrawlerKey(),
                crawlerJob.generateCrawlerTriggerKey(),
                QimaiPublishCrawlerSchedulerJob.domain,
                CrawlerMetaConstant.ScheduleJobTrigger_Cron,
                "0 0 17 * * ?",
                "七麦小米  采集任务执行，每天17开始执行"
        );
    }
    //vivo采集
    public static void publishQimaivivoRealtimeCrawlerScheduleTriggerInfo(){
        CrawlerJob crawlerJob = QimaiPublishCrawlerSchedulerJob.vivo();

        metaServiceCommand_17.addOrUpdateScheduleCrawlerTrigger(
                crawlerJob.generateCrawlerKey(),
                crawlerJob.generateCrawlerTriggerKey(),
                QimaiPublishCrawlerSchedulerJob.domain,
                CrawlerMetaConstant.ScheduleJobTrigger_Cron,
                "0 0 17 * * ?",
                "七麦vivo 采集任务执行，每天17开始执行"
        );
    }



}
